package cn.echoedu.specifics;

import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;

import cn.echoedu.daoconstants.TableName;
import cn.echoedu.entity.School;
import cn.echoedu.entity.SchoolCalendar;
import cn.echoedu.util.L;

public class SpecSchoolCalendar extends BaseSpec{

	@Override
	public <T> PreparedStatement getPreparedInsert(Connection con,
			TableName tableName, T currentPojo) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public <T> PreparedStatement getPreparedInsertRunning(Connection con,
			TableName tableName, T currentPojo) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public <T> PreparedStatement getPreparedListInsert(Connection con,
			TableName tableName, T currentPojo) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public <T> PreparedStatement getPreparedListInsertRunning(Connection con,
			TableName tableName, T currentPojo) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public Object getPojo(ResultSet rs) throws SQLException {
		// TODO Auto-generated method stub
		SchoolCalendar schoolcalendar = new SchoolCalendar();
		schoolcalendar.setSchoolcalendarid(
				rs.getInt("schoolcalendar.schoolcalendarid"));
		L.p("id"+schoolcalendar.getSchoolcalendarid());
		schoolcalendar.setTitle(
				rs.getString("schoolcalendar.title"));
		L.p("title"+schoolcalendar.getTitle());
		schoolcalendar.setContent(
				rs.getString("schoolcalendar.content"));
		L.p("content"+schoolcalendar.getContent());
		schoolcalendar.setYear(
				rs.getString("schoolcalendar.publishyear"));
		L.p("year"+schoolcalendar.getYear());
		School school = new School();
		school.setSchoolcode(rs.getInt("schoolcalendar.schoolcode"));
		L.p("schoolid"+schoolcalendar.getSchool());
		schoolcalendar.setSchool(school);
		return schoolcalendar;
	}

	@Override
	public <T> PreparedStatement getPreparedUpdate(Connection con,
			TableName tableName, T oldPojo, T currentPojo) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public <T> String getPreparedInsertGetPrimaryKeySql(Connection con,
			TableName tableName, T currentPojo) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public Object getLeftJoinPojo(ResultSet rs) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public Object getPojoBySql(ResultSet rs) throws SQLException {
		// TODO Auto-generated method stub
		return null;
	}

}
